package com.gzq.factorymethod.exam90;

public class SuperFactory implements IFactory {

	@Override
	public <T extends IProduct> T create(Class<?> c) {
		try {
			return (T) c.newInstance();
		} catch (InstantiationException | IllegalAccessException e) {
			e.printStackTrace();
		}
		return null;
	}

}
